package cn.edu.xmut.chen.zhlg.zhlg.user.entity;

import cn.edu.xmut.chen.zhlg.common.utils.BaseEntity;
import cn.edu.xmut.chen.zhlg.zhlg.user.userenum.SexEnum;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonView;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.time.LocalDateTime;
import java.util.Date;

@TableName("tb_user")
@Data
@ApiModel(value = "User对象", description = "用户表")
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
public class User extends BaseEntity {

    @ApiModelProperty(value = "电话号码", required = true)
    @TableField("phone")
    private String phone;

    @ApiModelProperty(value = "创建时间", required = true)
    @TableField("create_time")
    private LocalDateTime createTime;

    @ApiModelProperty(value = "头像URL")
    @TableField("pic")
    private String pic;

    @ApiModelProperty(value = "信誉分", required = true)
    @TableField("credit")
    private Float credit;

    @ApiModelProperty(value = "昵称", required = true)
    @TableField("nick_name")
    private String nickName;

    @ApiModelProperty(value = "个人简介", required = true)
    @TableField("bio")
    private String bio;

    @ApiModelProperty(value = "公司id", required = true)
    @TableField("company_id")
    private String companyId;

    @ApiModelProperty(value = "性别", required = true)
    @TableField("sex")
    private SexEnum sex;

    @ApiModelProperty(value = "地区", required = true)
    @TableField("region")
    private String region;

    @ApiModelProperty(value = "角色", required = true)
    @TableField("role")
    private String role;
}